﻿@model IEnumerable<VideoCache.Server.Model.EpisodeInfo>
@{
    ViewBag.Title = "剧集列表";
    Layout = null;
}
<p>
    @Html.ActionLink("新建", "Create", new { albumId=ViewBag.AlbumId, siteId=ViewBag.SiteId })
    @if (ViewBag.AllowDownload)
    {
        <a href="@Url.Action("SetDownload", "Album", new {albumId = ViewBag.AlbumId, siteId = ViewBag.SiteId})">设为下载点</a>
    }
</p>
<table width="100%" class="list">
<thead>
    <tr>
        <th width="10"><input type="checkbox" group="chkEpisode" class="selectAll" /></th>
        <th width="100">剧集</th>
        <th width="100">视频名称</th>
        <th width="200">视频标记</th>
        <th>网址</th>
        <th width="120">更新时间</th>
        <th width="120"></th>
    </tr>
</thead>
<tbody>
@foreach (var item in Model)
{
    <tr>
        <td><input type="checkbox" group="chkEpisode" value="@item.Id" /></td>
        <td>@item.EpisodeIndex</td>
        <td>@item.Name</td>
        <td>@item.Token</td>
        <td>@item.Url</td>
        <td>@String.Format("{0:g}", item.ModifyTime)</td>
        <td>
            @Html.ActionLink("修改", "Edit", new { id = item.Id }) |
            @Html.ActionLink("删除", "Delete", new { id = item.Id }, new { @class = "delete" })
        </td>
    </tr>
}
</tbody>
</table>